<include file="Index:header" />
<link rel="stylesheet" href="__PUBLIC__/jc/css/lrtk.css">
<link rel="stylesheet" href="__PUBLIC__/css/style.css">
<!--头部 end -->
<!--主体 -->
<div id="login">
    <div class="wrapper">
        <div class="login">
             <form id="myform" name="myform" method="post" action='__URL__/replacement' class="container offset1 loginform">
                <div id="owl-login">
                    <div class="hand"></div>
                    <div class="hand hand-r"></div>
                    <div class="arms">
                        <div class="arm"></div>
                        <div class="arm arm-r"></div>
                    </div>
                </div>
                <div class="pad">
                    <div class="control-group">
                        <div class="controls">
                            <label class="control-label fa fa-mobile" style="font-size: 22px;top: 10px;"></label>
                            <input type="text" id="phone" maxlength="11" class="form-control input-medium" value="{$name}">
                            <input name="id" type="hidden" value="{$id}" />
                        </div>
                        <div class="Validform_checktip"></div>
                    </div>
                    <div class="control-group">
                        <div class="controls">
                            <label class="control-label fa"></label>
                            <input name="cellpcode" datatype="*" nullmsg="请输入手机验证码！" ajaxurl="__URL__/ajaxverify" placeholder="手机验证码"  maxlength="6" class="form-control input-medium" style="width:50%"><input style="width:35%;position: absolute;top: 0px;right:5px;color: #FFF;padding-left:0px;" type="button" id="btn" value="免费获取验证码"  class="btn btn-primary" ajaxurl="__URL__/ajaxverify"/><span id="abc"></span>
                        </div>
                        <div class="Validform_checktip"></div>
                    </div>
                    <div class="control-group">
                        <div class="controls">
                            <label class="control-label fa fa-asterisk"></label>
                            <input id="password"  nullmsg="请输入新密码！" datatype="*" type="password" name="password" placeholder="设置新密码" class="form-control input-medium">
                        </div>
                        <div class="Validform_checktip"></div>
                    </div>
                    
                </div>
                <div class="form-actions">
                    <button type="submit" tabindex="4" class="btn btn-primary">提交</button>
                </div>
                <input id="vnumber" type="hidden" value="1" />
            </form>
        </div>
    </div>
    
</div>
<!-- 主体 end-->
<!--底部 -->

<script src="__PUBLIC__/jquery/Validform_v5.3.2min.js"></script>
<script language="JavaScript">
 $(function(){
	//$(".form-horizontal").Validform();  //就这一行代码！;

	$("#myform").Validform({
		tiptype:2,
		datatype:{
			"me" : /^[\u4E00-\u9FA5\uf900-\ufa2d\w]{2,16}$/,
		}
	});
})
</script>
<script type="text/javascript">
//获取验证码倒计时
var wait=60;
function time(o) {
		if (wait == 0) {
			o.removeAttribute("disabled");			
			o.value="免费获取验证码";
			wait = 60;
		} else {
			o.setAttribute("disabled", true);
			o.value="重新发送(" + wait + ")";
			wait--;
			setTimeout(function() {
				time(o)
			},
			1000)
		}
	}
$(function(){
	$('#btn').click( function () { 
		var phone=$('#phone').val();
		var number=$('#vnumber').val();
		var myreg = /^13[0-9]{9}$|14[0-9]{9}|15[0-9]{9}$|16[0-9]{9}$|17[0-9]{9}$|18[0-9]{9}$/;
		if(number<1){
			 alert('输入的手机号未通过验证！');
            return false;
		}
		 if(!myreg.test(phone))
        {
            alert('请输入有效的手机号码！');
            return false;
        }
		time(this); 
		//$.post("__URL__/cellpcode", {id:1} );
		$('#abc').load("__URL__/reMessages", {phone:phone} );
	});
});
</script>
<include file="Index:footer" />
<!--底部 end-->
